/**       
 * @{#} ResourceManager.java Create on 2012-3-28 下午2:52:33       
 *       
 * Copyright (c) 2012 by able.       
 */
package __javable.core.util;

import java.util.ResourceBundle;

/**
 * 
 * 
 * @history <PRE>
 * --------------------------------------------------------- 
 * VERSION       DATE            BY       CHANGE/COMMENT 
 * --------------------------------------------------------- 
 * 1.0           2012-3-28      able         create 
 * ---------------------------------------------------------
 * </PRE>
 * 
 */
public class ResourceManager {

	private static ResourceBundle r;

	static {
		r = ResourceBundle.getBundle("resourceBundle");
	}

	public static String getDriverClass() {
		return r.getString("connection.driverClass");
	}

	public static String getUrl() {
		return r.getString("connection.url");
	}

	public static String getUsername() {
		return r.getString("connection.username");
	}

	public static String getPassword() {
		return r.getString("connection.password");
	}

	public static int getPoolSize() {
		int poolSize = Integer.valueOf(r.getString("connection.poolSize"));
		return poolSize;
	}

	public static void refresh() {
		r = ResourceBundle.getBundle("resourceBundle");
	}
}
